package visitor.general;

/**
 * @Author：LJ
 * @Description：
 * @Date: 2017/12/3
 * @Modified By:
 */
public class Visitor implements IVisitor {
    //访问ConcreteElement1元素
    @Override
    public void visit(ConcreteElement1 concreteElement1) {
        concreteElement1.doSomething();
    }

    //访问ConcreteElement2元素
    @Override
    public void visit(ConcreteElement2 concreteElement2) {
        concreteElement2.doSomething();
    }
}
